package jp.ac.aiit.yc.softarch.hbcp.service.common;

import java.util.Calendar;
import java.util.Date;
import java.util.GregorianCalendar;

public class CalendarUtil {

	public static String nowDate(){

		Calendar calendar = new GregorianCalendar();
		Date trialTime = new Date();
		calendar.setTime(trialTime);
		StringBuffer sb = new StringBuffer();
		sb.append(calendar.get(Calendar.YEAR) + ".");
		int month = calendar.get(Calendar.MONTH) + 1;
		sb.append(month + ".");
		sb.append(calendar.get(Calendar.DATE) + ":");
		sb.append(calendar.get(Calendar.HOUR_OF_DAY) + ".");
		sb.append(calendar.get(Calendar.MINUTE) + ".");
		sb.append(calendar.get(Calendar.SECOND) + ".");
		sb.append(calendar.get(Calendar.MILLISECOND));
		return sb.toString();

	}

}
